<template>
  <div @click="$router.push(to)">{{title}}</div>
</template>

<script>
import { useParent } from '@vant/use'
import { TABS_KEY } from '@/components/Tabs.vue'
export default {
  props: {
    title: {
      type: String,
      required: true
    },
    to: {
      type: [Object, String],
      required: false
    }
  },
  setup (props) {
    var {
      parent,
      index
    } = useParent(TABS_KEY)
    return {
    }
  }
}
</script>

<style scoped>
.tabs-wrap div {
  text-align: center;
  width: 100%;
}
</style>